<?php

header('Content-type: application/json');
$nss = $viewModel->get("nsList");
if ($nss == NULL) {
    $nss = array();
} else {
    foreach ($nss as $ns) {
        $ns->news_name = $sbj->news_name;
    }
}
echo $a = json_encode($nss);